(function (){
	var mCharts = echarts.init(document.querySelector("#bubble"))
	var option = {
		title:{
			text:'气泡图',
			top:'3%',left:'center'
		},
		legend: {},
		tooltip: {
			trigger: "item",
			axisPointer: {
				type: "shadow"
			},
			position: function (pos, params, el, elRect, size) {
				var obj = {top: 10};
				obj[['left', 'right'][+(pos[0] < size.viewSize[0] / 2)]] = 30;
				return obj;
			},
			extraCssText: 'width: 170px'
		},
		grid:[
			{bottom:61,left:'center'},
			{height:60,
				bottom:0,
				left:'center'}
		],
		dataset:{
			source:scadata
		},
		xAxis:
				{
					type:'value',
					scale:true
				},

		yAxis:
				{
					type:'value',
					scale:true
				},
		series:
				{
					type:'scatter',
					symbolSize: function (arg) {
						// console.log(arg);
						// arg字典形式
						var deny=arg["deny"];
						var denyTime=arg.denyTime;
						var divided =(deny/denyTime)*70;
						return divided
					}
					
				}

	};
	mCharts.setOption(option)
})();